{% load static %}
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" name="viewport" />
    <title>{% block title %}文章编辑{% endblock %}</title>
    <link href="{% static 'bootstrap-3.3.7-dist/css/bootstrap.min.css' %}" rel="stylesheet">
    <link href="{% static 'css/blogbase.css' %}" rel="stylesheet">
    <script src="{% static 'js/jquery-3.2.1.min.js' %}"></script>
    <script src="{% static 'bootstrap-3.3.7-dist/js/bootstrap.min.js' %}"></script>
</head>
<body>
    {% include "blog/nav.html" %}
    <div id="main" class="container col-md-offset-2 col-md-8">
        {% block main %}
            <div class="panel-title">
                    <h2>文章编辑</h2>
            </div>
            <form method="POST" action="{% url 'blog:article_update' article.id article.slug %}">
            {% csrf_token %}
                {{ form.media }}
                <div class="form-group">
                    <label for="title">{{ form.title.label }}</label>
                    {{ form.title }}
                </div>
                <div class="form-group">
                    <label for="category">{{ form.category.label }}</label>
                    {{ form.category }}
                </div>
                <div class="form-group">
                    <label for="tags">{{ form.tags.label }}</label>
                    {{ form.tags }}
                </div>
                <div class="edit-area">
                    <label for="content">正文</label>
                    {{ form.body }}
                </div>
                <div class="edit-area">
                    <label for="form-group">{{ form.status.label }}</label>
                    {{ form.status }}
                </div>
                <div class="pull-right">
                    <button type="submit" class="btn btn-danger">提 交</button>
                </div>
            </form>
        {% endblock %}
    </div>
</body>
</html>